<!doctype html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>Spark test page</title>
		<script type="text/javascript" src="../lib/jquery-1.4.4.js"></script>
		<script type="text/javascript" src="../lib/jquery.dump.js"></script><!-- TODO remove from production -->
		<script type="text/javascript" src="../lib/jquery.mapAttributes.js"></script>
		<script type="text/javascript" src="../lib/jquery.xdomain.js"></script>
		<script type="text/javascript" src="../lib/jquery.jqplot.js"></script>
		<script type="text/javascript" src="../lib/jqplot.pieRenderer.js"></script>
		<script type="text/javascript" src="../lib/jqplot.dateAxisRenderer.js"></script>
		<script type="text/javascript" src="../src/jquery.spark.js"></script>
		<script type="text/javascript" src="test.js"></script>
		<link rel="stylesheet" href="../docs/screen.css" type="text/css" media="screen, projection">
		<link rel="stylesheet" href="../docs/print.css" type="text/css" media="print">
		<link rel="stylesheet" href="../lib/jquery.jqplot.min.css" type="text/css">
	</head>
	<body>
		<div class="container">
			<div class="span-24 last prepend-top">
				<h1>Testing Spark</h1>
				<p>
					In this page we test the spark plugin. We simply pull in
					some data from an external SPARQL endpoint. As far as I
					know it works with Firefox 3.5, Safari 5, Chrome 9.
					It seem not to work with IE8 or Opera 11. I do not know
					about older versions. Please let me know.
				</p>
				<p>
					See <a href="index.html">the dynamic version</a>, with
					static SPARQL results coming from an actual SPARQL
					endpoint.
				</p>
				<p>
					Denny's friends are
					<span class="spark"
						data-spark-endpoint="sparql1"
						data-spark-ns-simia="http://simia.net/foaf.rdf#"
						data-spark-param-lastconjunct=", and "
						data-spark-param-head="nohead2"
						data-spark-format="simple"
						data-spark-query="select ?name ?link
							where { 
								simia:denny foaf:knows ?p .
								?p foaf:name ?name .
								?p foaf:mbox_sha1sum ?mail.
							}"
					>
						<em>loading&hellip;</em>
					</span>.
				</p>
				<p>
					Party results.
					<div class="spark"
						data-spark-endpoint="sparql2"
						data-spark-format="http://localhost/~denny/spark/rdf-spark/src/jquery.spark.datechart.js"
						data-spark-query="select ?uri ?series ?series_label ?time ?value
							where {
								?uri foaf:party ?series . ?series rdfs:label ?series_label .
								?uri foaf:voters ?value .
							}"
					>
						<em>loading&hellip;</em>
					</div>		
				</p>
				<p>
					Pie charts are evil. But they look pretty.
					<div class="spark"
						data-spark-endpoint="sparql3"
						data-spark-format="http://localhost/~denny/spark/rdf-spark/src/jquery.spark.piechart.js"
						data-spark-query="select ?uri ?label ?value
							where {
								?uri foaf:party ?p . ?p rdfs:label ?label .
								?uri foaf:voters ?value .
							}"
					>
						<em>loading&hellip;</em>
					</div>		
				</p>
			</div>
		</div>
	</body>
</html>